﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Common;
using Services;
using EntityModel;
namespace ShopWeb.Controllers
{
    public class ProductController : Controller
    {
        #region 公用属性
        private ProductService productService = new ProductService();
        private ProductAlbumService productAlbumService = new ProductAlbumService();
         
        #endregion

        public ActionResult Index()
        {
            return View();
        }
        public ActionResult Detail(int pid)
        {
            ViewData["AlbumList"] = productAlbumService.GetAllList(pid);
            Product p = productService.GetModel(pid);
            return View(p);
        }
        public ActionResult haha()
        {
            productService.GetAllPruductById(2);
            return View();
        
        }
     
        

    }
}
